<template>
    <div  class="educationnewsDetail">
         <p class="clearfix"> <el-button class="fr" type="custom" @click="toback()" plain >返回上一页</el-button></p>
        <div  class="newsDetail" v-if="content">

            <div class="text" v-html="content">
                    {{ content}}
            </div>
        
        </div>
        <div v-else>
            <el-empty  description="暂无数据"></el-empty>
        </div>
       
    </div>
</template>


<script>
import { openApiSysIdeologicalEducationQuery } from "@/api/openApi";
export default {
  
    data() {
        return {
            dataPage:{},
            listType:1,
            ids:'',
            content:"",
             listQuery: {
                //首页图数据源查询条件
                page: 1,
                limit: 15,
                id:'',
               
            },
           
        } 
    },
     watch: {
        $route(to,from){
        
           this.listQuery.id = this.$route.query.id;
            this.getList();
        },
        listType(val){
          //  console.log(val)
        }
    },
    methods: {
         getList() {
            openApiSysIdeologicalEducationQuery(this.listQuery).then((res) => {
              
                //  this.pageObj = res.data;
                // this.dataList = res.data.data[0].childList;
                
            });
        },
       
        toback(){
            
        
              this.$router.go(-1);
        }
      
    },
    created() {
        this.listQuery.id =this.$route.query.id;
     
         this.getList();

    },
}
</script>

<style  lang="scss" >
.educationnewsDetail{
     .title {
        font-size: 28px;
        font-weight: 900;
        text-align: center;
        padding-top: 20px;
        color: #a7201f;
    }
    .subTitle {
        text-align: center;
        font-size: 16px;
        padding: 15px 0;
    }
    .title-detail {
        text-align: center;
        span {
        display: inline-block;
        padding-right: 30px;
        color: #909399;
        font-size: 12px;
        }
        border-bottom: 1px dashed #ddd;
        margin: 10px 25px;
        padding-bottom: 20px;
    }
    .text {
        padding: 20px;
        text-indent:2em;
    }
}
</style>

